package com.huilan.hgt.entity;

import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.huilan.hgt.base.BaseModel;
import com.baomidou.mybatisplus.annotation.TableField;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;

/**
 * <p>
 * 日志表
 * </p>
 *
 * @author ghy
 * @since 2018-11-09
 */
@Data
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
@TableName("T_LOG")
public class Log extends BaseModel<Log> {

    private static final long serialVersionUID = 1L;

        /**
     * 日志ID
     */
         @TableId(value = "LOG_ID", type = IdType.AUTO)
    private Integer logId;

        /**
     * 模块名称
     */
         @TableField("MODEL_NAME")
    private String modelName;

        /**
     * 方法类型
     */
         @TableField("METHOD_TYPE")
    private String methodType;

        /**
     * 方法名称
     */
         @TableField("METHOD_NAME")
    private String methodName;

        /**
     * 方法描述
     */
         @TableField("METHOD_DESC")
    private String methodDesc;

        /**
     * 方法请求路径
     */
         @TableField("METHOD_URL")
    private String methodUrl;

        /**
     * 操作者ip
     */
         @TableField("IP")
    private String ip;


    public static final String LOG_ID = "LOG_ID";

    public static final String MODEL_NAME = "MODEL_NAME";

    public static final String METHOD_TYPE = "METHOD_TYPE";

    public static final String METHOD_NAME = "METHOD_NAME";

    public static final String METHOD_DESC = "METHOD_DESC";

    public static final String METHOD_URL = "METHOD_URL";

    public static final String IP = "IP";

    @Override
    protected Serializable pkVal() {
        return this.logId;
    }

}
